﻿using System;
using System.Text;
using Irclib;
using System.Threading;
using System.Globalization;

namespace TestListener
{
    class Program
    {
        static void Main(string[] args)
        {
            //IrcConnection connection = new SecureIrcConnection(new Uri("irc://192.168.56.2:9999"), new ASCIIEncoding(), true);
            try
            {                
                //connection.Connect();
                //connection.Initialize();
                //connection.SetUser("test", "Testy mctest", false);
                //connection.SetNick("testybot");
                Thread.Sleep(15000);
                //connection.Join("#test");
                //connection.StartPing("penguin.omega.org.za");
                while (true)
                {
                    //string response;
                    //while ((response = connection.ReadLine()) != null)
                    //{
                    //    System.Console.WriteLine(response);
                    //}
                    //string tosend;
                    //if ((tosend = System.Console.ReadLine()) != null)
                    //{
                    //    if (tosend.StartsWith("/quit", true, CultureInfo.InvariantCulture))
                    //        connection.Quit(null);
                    //    connection.Privmsg("#test", tosend);
                    //}
                }
            }
            finally
            {
                //connection.Dispose();
            }
        }
    }
}
